//
//  QNOptionItem.swift
//  OptionButton
//
//  Created by Joggy on 15/11/17.
//  Copyright © 2015年 NUPT. All rights reserved.
//

import UIKit

class QYOptionItem: UIView {
    
    var button: UIButton!
    var title: UILabel!

    override init(frame: CGRect) {
        super.init(frame: frame)
        button = UIButton(type: UIButtonType.custom)
        button.frame = CGRect(x: 0, y: 0, width: frame.width, height: frame.width)
        self.addSubview(button)
        title = UILabel(frame: CGRect(x: -frame.width*0.1, y: frame.height - 20, width: frame.width*1.2, height: 20))
        title.font = UIFont.systemFont(ofSize: 14)
        title.textColor = UIColor.white
        title.textAlignment = NSTextAlignment.center
        self.addSubview(title)
    }

    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
}
